package banking9;

import banking9.CheckingAccount;
import banking9.SavingsAccount;

import java.util.ArrayList;
import java.util.List;

/**
 * Created with IntelliJ IDEA
 * Description:
 * User:恋恋
 * Date:2022-11-17
 * Time:14:47
 */
public class Customer {
    List<Account> accounts = new ArrayList<>();
    //a
    private String firstName;
    private String lastName;

    public Customer(String firstName, String lastName) {
        this.firstName = firstName;
        this.lastName = lastName;
    }

    public boolean addAccount(Account account){
        return accounts.add(account);
    }
    public Account getAccount(int i){
        return accounts.get(i);
    }
    public int getAccountNumber(){
        return accounts.size();
    }




    public String getFirstName() {
        return firstName;
    }

    public String getLastName() {
        return lastName;
    }


}
